package service.handle;

import relations.Associate;
import relations.belongsTo;
import relations.handle;
import dao.AlbumDAO;
import dao.AssociateDAO;
import dao.HandleDAO;
import dao.RecordDuplicateException;
import dao.belongsToDAO;
import entities.Customer;
import entities.User;
import entities.Album;
import entities.Order;



public class handleServiceInMemory implements handleService {

	public handleServiceInMemory(){
		
	}
	
	public static handleService newInstance(){
		return new handleServiceInMemory();
	}
	
	/**
	 * Finds a Album based on the Album id.
	 * @param userid - user id
	 * @return the instance of the Album
	 */
	public handle findHandle(String userID, Long product_id, String dateDay, String dateMonth, String dateYear, String description){
		HandleDAO db =  HandleDAO.getInstance();
		handle result = null;
		result = db.findHandle(userID, product_id, dateDay, dateMonth, dateYear, description);
		return result;
	}
	
	
	/**
	 * Adds a new Album to the system.
	 * @param obj - the Album instance to add
	 */
	
	public void addHandle(handle obj) throws RecordDuplicateException{
		HandleDAO db = HandleDAO.getInstance();	
		db.addHandle(obj);
		return;
	}











}
